<?php
#####################################
# * @Author: lehieu008              #
# * @Email: lehieu008@gmail.com     #
# * @Copyright: 2008 - 2010         #
#####################################
if(!defined('BASEPATH'))exit('No direct script access allowed');
class Message_module extends Controller
{
    function __construct()
    {
        parent::Controller();
    }
    
    function index($message = '')
    {
        if(trim($message) != '')
        {
            $data['message'] = $message;
        }
        else
        {
            $data['notice'] = $this->global_model->get("SELECT notID, notTitle, notDetail FROM {PRE}notice WHERE notGroup = 'ALL' AND notStatus = 1 AND notExpireDate >= ".time()." ORDER BY notHome DESC, notID DESC");
        }
        #Load View
        $this->load->view('message/defaults', $data);
    }
}